package com.wn.mapper;

import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Update;

public interface AccountMapper {

    //转入
    @Update("update account set balance = balance + #{money} where name = #{name}")
    void inMoney(@Param("name") String name, @Param("money") int money);

    //转出
    @Update("update account set balance = balance - #{money} where name = #{name}")
    void outMoney(@Param("name") String name, @Param("money") int money);
    
}